package cn.sofwin.web.blog.service.impl;

import cn.sofwin.core.dao.BaseDao;
import cn.sofwin.core.service.impl.BaseServiceImpl;
import cn.sofwin.web.blog.dao.ArticleCommentDao;
import cn.sofwin.web.blog.dao.UserDao;
import cn.sofwin.web.blog.entity.ArticleComment;
import cn.sofwin.web.blog.entity.User;
import cn.sofwin.web.blog.service.ArticleCommentService;
import cn.sofwin.web.blog.service.UserService;

/**
 * 文章评论服务接口的实现
 * @author ZX
 * @version 1.0
 */
public class ArticleCommentServiceImpl extends BaseServiceImpl<ArticleComment> implements ArticleCommentService {
    /** 用户数据访问对象 */
    private ArticleCommentDao articleCommentDao = new ArticleCommentDao();

    /** 私有的实例对象，用户实现单例模式 */
    private static ArticleCommentServiceImpl articleCommentService = new ArticleCommentServiceImpl();

    /**
     * 将构造方法设为私有，用于实现单例模式
     */
    private ArticleCommentServiceImpl(){
        super();
    }

    /**
     * 对外提供的静态方法，用于获取服务实例
     * @return
     */
    public static ArticleCommentService getInstance(){
        return articleCommentService;
    }


    @Override
    protected BaseDao<ArticleComment> getDao() {
        return articleCommentDao;
    }



}